Skip to content

Clarify accessibility criteria descriptions#1404

Closed
scottaohara wants to merge 1 commit intogithub:stagedfrom
scottaohara:patch-2
Closed

Clarify accessibility criteria descriptions#1404
scottaohara wants to merge 1 commit intogithub:stagedfrom
scottaohara:patch-2

Conversation

@scottaohara
Copy link
Copy Markdown
Contributor

Pull Request Checklist


Description

I have not been able to look through everything in the accessibility instruction file. But the changes I'm submitting attempt to clarify / correct content that needed it.


Type of Contribution

  • Update to existing instruction, prompt, agent, plugin, skill, or workflow.

By submitting this pull request, I confirm that my contribution abides by the Code of Conduct and will be licensed under the MIT License.

I have not been able to look through everything in the accessibility instruction file. But the changes I'm submitting attempt to clarify / correct content that needed it.
Copilot AI review requested due to automatic review settings April 15, 2026 15:22
@scottaohara scottaohara deleted the patch-2 branch April 15, 2026 15:23
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the accessibility instruction documentation (a11y.instructions.md) to clarify several WCAG 2.2 quick-reference summaries and refine guidance in specific anti-pattern sections.

Changes:

  • Refined multiple WCAG 2.2 quick reference summaries (e.g., meaningful sequence, reflow, pointer cancellation, target size).
  • Adjusted wording in the “Five Rules of ARIA” section and updated several ARIA/keyboard anti-pattern guidance paragraphs.
  • Added/updated explanatory notes in a few anti-pattern sections (e.g., role="presentation" behavior, live regions, modal focus management).

| 2.5.4 Motion Actuation | A | Device motion has UI alternative and can be disabled. |
| 2.5.7 Dragging Movements | AA | Drag-and-drop has click/tap alternative. *(New in 2.2)* |
| 2.5.8 Target Size (Minimum) | AA | Touch targets at least 24x24 CSS px. *(New in 2.2)* |
| 2.5.8 Target Size (Minimum) | AA | Interactive controls have a target size, or spacing of at least 24x24 CSS px. *(New in 2.2)* |

1. **Prefer native HTML** — Use `<button>` not `<div role="button">`. Native elements have built-in keyboard, focus, and semantics.
2. **Don't change native semantics** — Don't add `role="heading"` to a `<button>`. Use the correct element.
2. **Don't change native semantics where prohibited** — Don't add `role="heading"` to a `<button>`. Use the correct element.
- **WCAG**: 2.1.2 (A)

Use native `<dialog>` with `showModal()` — it provides focus trapping, Escape-to-close, and focus return automatically. Use `inert` attribute on background content to prevent interaction outside the dialog (96%+ browser support). If custom implementation is needed: trap Tab within the dialog, close on Escape, return focus to the trigger element on close.
Use native `<dialog>` with `showModal()` — it prevents focus from moving to the inert non-dialog content, Escape-to-close, and focus return automatically. If custom implementation is needed: trap Tab within the dialog or use the `inert` attribute for non-dialog content (do not use `inert` on an element that contains the dialog), close on Escape (unless user confirmation of an action is essential), return focus to the trigger element on close, or to best logical location if triggering element is no longer present upon dismissal.
- **WCAG**: 2.1.2 (A)

Use native `<dialog>` with `showModal()` — it provides focus trapping, Escape-to-close, and focus return automatically. Use `inert` attribute on background content to prevent interaction outside the dialog (96%+ browser support). If custom implementation is needed: trap Tab within the dialog, close on Escape, return focus to the trigger element on close.
Use native `<dialog>` with `showModal()` — it prevents focus from moving to the inert non-dialog content, Escape-to-close, and focus return automatically. If custom implementation is needed: trap Tab within the dialog or use the `inert` attribute for non-dialog content (do not use `inert` on an element that contains the dialog), close on Escape (unless user confirmation of an action is essential), return focus to the trigger element on close, or to best logical location if triggering element is no longer present upon dismissal.
| 1.4.4 Resize Text | AA | Text resizable to 200% without loss of content. |
| 1.4.10 Reflow | AA | Content reflows at 320px CSS width (no horizontal scroll). |
| 1.4.4 Resize Text | AA | Text resizable to 200% without loss of content or functionality. |
| 1.4.10 Reflow | AA | Sections of content can fit within 320px CSS width viewports without needing to scroll in two dimensions to read. |
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants